<?php /* Smarty version 2.6.18, created on 2008-06-12 23:40:10
         compiled from admin/Websetup_usergroup_list.html */ ?>
<table id="ugList">
<tr id="tr_0">
	<th colspan="2">用户组列表</th>
	<td><a href="?controller=admin_user&action=userlist">全部用户</a></td>
	<td><a class="ugAdd" href="0">添加根类</a></td>
	<td></td>
</tr>
<?php unset($this->_sections['i']);
$this->_sections['i']['name'] = 'i';
$this->_sections['i']['loop'] = is_array($_loop=$this->_tpl_vars['ugList']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['i']['show'] = true;
$this->_sections['i']['max'] = $this->_sections['i']['loop'];
$this->_sections['i']['step'] = 1;
$this->_sections['i']['start'] = $this->_sections['i']['step'] > 0 ? 0 : $this->_sections['i']['loop']-1;
if ($this->_sections['i']['show']) {
    $this->_sections['i']['total'] = $this->_sections['i']['loop'];
    if ($this->_sections['i']['total'] == 0)
        $this->_sections['i']['show'] = false;
} else
    $this->_sections['i']['total'] = 0;
if ($this->_sections['i']['show']):

            for ($this->_sections['i']['index'] = $this->_sections['i']['start'], $this->_sections['i']['iteration'] = 1;
                 $this->_sections['i']['iteration'] <= $this->_sections['i']['total'];
                 $this->_sections['i']['index'] += $this->_sections['i']['step'], $this->_sections['i']['iteration']++):
$this->_sections['i']['rownum'] = $this->_sections['i']['iteration'];
$this->_sections['i']['index_prev'] = $this->_sections['i']['index'] - $this->_sections['i']['step'];
$this->_sections['i']['index_next'] = $this->_sections['i']['index'] + $this->_sections['i']['step'];
$this->_sections['i']['first']      = ($this->_sections['i']['iteration'] == 1);
$this->_sections['i']['last']       = ($this->_sections['i']['iteration'] == $this->_sections['i']['total']);
?>
<tr id="tr_<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
">
	<th><?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['levelstr']; ?>
 <?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['group_name']; ?>
</th>
	<td><a href="#" onclick="ugModify(<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
,'<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['group_name']; ?>
','<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['description']; ?>
');">修改</a></td>
	<td><a href="?controller=admin_user&action=userlist&ug_id=<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
" title="查看本组成员">用户(<span class="red"><?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['has_members']; ?>
</span>)</a></td>
	<td><a class="ugAdd" href="<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
">添加子类</a></td>
	<td><a class="band" href="#" user_group_id="<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
" title="绑定角色或权限">绑定</a></td>
	<td><a class="removeUserGroup" id="<?php echo $this->_tpl_vars['ugList'][$this->_sections['i']['index']]['user_group_id']; ?>
" href="#">删除</a></td>
</tr>
<?php endfor; endif; ?>
</table>

<!-- 修改用户组的表单 -->
<div id="formModifyUserGroupBox" class='hideme'>
<form id='formModifyUserGroup' action='?controller=admin_usergroup&action=modifyusergroup' method='post'>

	<table>
		<tr>
			<th>ID:</th>
			<td>
				<input id='user_group_id' name='user_group_id' type='text' readonly='readonly' size='4' /> * 不可修改
			</td>
		</tr>
		<tr>
			<th>父类:</th>
			<td><select id="select_fclass" name="parent_id"></select> * 如不需修改请留空</td>
		</tr>
		<tr>
			<th>用户组名:</th>
			<td>
				<input id='group_name' name='group_name' type='text' size='50'
			 	class='required' title='用户组名不能为空' alt="{event: 'blur'}" />
			</td>
		</tr>
		<tr>
			<th>描述:</th>
			<td><input id='description' name='description' type='text' size='50' /></td>
		</tr>
		<tr>
			<th></th>
			<td>
				<input type='submit' value='修改' class='submitbutton' />
				<input type='button' value='取消' class='submitbutton' onclick='_removeModifyForm();' />
			</td>
		</tr>
	</table>
	
</form>

<form id='formAddUserGroup' action='?controller=admin_usergroup&action=modifyusergroup' method='post'>

	<table>
		<tr>
			<th>父类ID:</th>
			<td><input id='parent_id' name='parent_id' type='text' readonly='readonly' size='4' /></td>
		</tr>
		<tr>
			<th>用户组名:</th>
			<td>
				<input id='group_name' name='group_name' type='text' size='50'
			 	class='required' title='用户组名不能为空' alt="{event: 'blur'}" />
			</td>
		</tr>
		<tr>
			<th>描述:</th>
			<td><input id='description' name='description' type='text' size='50' /></td>
		</tr>
		<tr>
			<th></th>
			<td>
				<input type='submit' value='添加为子类' class='submitbutton' />
				<input type='button' value='取消' class='submitbutton' onclick='_removeModifyForm();' />
			</td>
		</tr>
	</table>
	
</form>
</div>

